﻿using System.ComponentModel.DataAnnotations;

namespace Model.DTO.Article
{
    /// <summary>
    /// 编辑文章DTO
    /// </summary>
    public class EditArticleDTO
    {
        /// <summary>
        /// 标题(32)
        /// </summary>
        [Required, MaxLength(32,ErrorMessage = "文章标题不能超过32位")]
        public string Title { get; set; }
        /// <summary>
        /// 内容(131072=>2^17)
        /// </summary>
        [Required, MaxLength(131072,ErrorMessage = "文章内容不能超过131072位")]
        public string Content { get; set; }
        /// <summary>
        /// 文章Id
        /// </summary>
        [Required]
        public long Id { get; set; }
        /// <summary>
        /// 审核类型Id
        /// </summary>
        [Required]
        public int CheckTypeId { get; set; }
        /// <summary>
        /// 状态类型Id
        /// </summary>
        [Required]
        public int StateTypeId { get; set; }
        /// <summary>
        /// 浏览数量
        /// </summary>
        [Required]
        public int ViewNumber { get; set; }
        /// <summary>
        /// 点赞数量
        /// </summary>
        [Required]
        public int LikeNumber { get; set; }
        /// <summary>
        /// 评论数量
        /// </summary>
        [Required]
        public int CommentNumber { get; set; }
        /// <summary>
        /// 收藏数量
        /// </summary>
        [Required]
        public int CollectNumber { get; set; }
        /// <summary>
        /// 备注
        /// </summary>
        [MaxLength(128, ErrorMessage = "备注不能超过128位")]
        public string? Remark { get; set; }
    }
}
